package com.rmi.service;

import javax.annotation.Resource;

import org.springframework.stereotype.Component;

import com.api.IOrderService;
import com.api.IUserService;
import com.api.req.OrderReq;
import com.rmi.anno.client.Remote;

@Component
public class AppService {
	@Remote
	private IUserService userService;
	@Remote
	private IOrderService orderService;
	@Resource
	private LocalService localService;
	public void getUser() {
		System.out.println(userService.getUserByName("admin")+localService.local());
		System.out.println(orderService.save(new OrderReq(99L, "小鸡小鸡")));
	}
}
